package com.lyx.question.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.lyx.question.entity.Question;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author 14667
 * @date 2022/7/20 15:31
 */
@Mapper
public interface QuestionMapper extends BaseMapper<Question> {
    List<Question> randomQuestionByTypeInChapter(@Param("questionType") Integer singleSelection, @Param("count") int i, @Param("chapterIds") List<Integer> chapterIds);

    List<Question> randomQuestionInchapter(@Param("chapterId") Integer chapterId, @Param("count") int i);


    List<Integer> correctQuestiontypeList(@Param("paperId") Integer paperId);


    boolean batchUpdateQuestionById(@Param("list") List<Question> questionList);


}
